#include "stm32f10x.h"                  // Device header
#include "Delay.h"
#include "OLED.h"
#include "CountSensor.h"
#include "Timer.h"
extern uint16_t frequency;

int main(void)
{
	/*模块初始化*/
	OLED_Init();			//OLED初始化
	CountSensor_Init();		//计数传感器初始化
	
    init_timer();
    
	/*显示静态字符串*/
	OLED_ShowString(1, 1, "Frequence:");	//1行1列显示字符串Count:
	
	while (1)
	{
        OLED_ShowNum(2, 1, frequency, 5);
        OLED_ShowString(2,6,"Hz");
        
		//OLED_ShowNum(3, 1, getCountAndReset(), 5);		//OLED不断刷新显示CountSensor_Get的返回值
	}
}
